package pl.un4giv3n.mightvsmagic.entity;

import java.io.Serializable;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;

/**
 * @author andrzejewskia
 * this is a single round in the fight report
 */
@Entity
public class Round implements Serializable{
	
	private static final long serialVersionUID = 1L;
	/**
	 * id
	 */
	private Long id;
	/**
	 * description of the round
	 */
	private String description;
	/**
	 * damage done by the attacker
	 */
	private double damage;
	/**
	 * attacker login
	 */
	private String attacker;

	@SuppressWarnings("unused")
	private Round(){}
	
	
	public Round(String description, double damage, User attacker) {
		this(description, damage, attacker.getLogin());
	}
	public Round(String description, double damage, String attackerLogin) {
		super();
		this.description = description;
		this.damage = damage;
		this.attacker = attackerLogin;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public double getDamage() {
		return damage;
	}

	public void setDamage(double damage) {
		this.damage = damage;
	}

	public String getAttacker() {
		return attacker;
	}

	public void setAttacker(String attacker) {
		this.attacker = attacker;
	}

	@Id
	@GeneratedValue
	public Long getId() {
		return id;
	}


	public void setId(Long id) {
		this.id = id;
	}

}
